home *** CD-ROM | disk | FTP | other *** search
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞
-
- CConnection.c
-
- CommToolbox connection class.
-
- SUPERCLASS = CBureaucrat.
-
- Copyright © 1992-93 Romain Vignes. All rights reserved.
-
- ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- #include <CommResources.h> /* Apple includes */
- #include <Connections.h>
-
- #include <CBartender.h> /* TCL includes */
- #include <CCluster.h>
- #include <CError.h>
- #include <Constants.h>
- #include <TBUtilities.h>
- #include <TCLUtilities.h>
-
- #include "CConnection.h" /* Other includes */
-
-
- /* Constants & Macros */
-
- #define CONN_STR_RES_ID 2100 /* Connection message resource ID */
-
- #define NO_TOOL_STR_INDEX 1 /* No connection tool */
- #define BAD_TOOL_STR_INDEX 2 /* Bad connection tool */
- #define NO_REC_STR_INDEX 3 /* Connection record allocation error */
- #define CHOOSE_STR_INDEX 4 /* Tool setup error */
- #define OPEN_ERR_STR_INDEX 5 /* Error on opening */
- #define CLOSE_ERR_STR_INDEX 6 /* Error on closing */
- #define WAIT_ERR_STR_INDEX 7 /* Waiting impossible */
-
- #define H_CHOOSE_POS 10 /* Setup dialog position */
- #define V_CHOOSE_POS 40
-
- #define BREAK_DELAY 5 /* Approximately 80 ms */
-
- #define FIRST_CONN_CMD cmdConnChoose /* First connection command */
- #define LAST_CONN_CMD cmdConnListen /* Last connection command */
-
- #define RESET_ALRT_ID 2100 /* Reset alert resource ID */
-
-
- /* Application globals */
-
- extern CBartender *gBartender;
- extern CError *gError;
-
-
- /* Class variables initialization */
-
- CCluster *CConnection::cConnList = NULL;
-
-
-
- /*
- * cIsConnectionCmd
- *
- * Command related to the connection object
- *
- * theCmd: command to analyse
- *
- * Return TRUE if the command is a connection command
- *
- */
-
- Boolean CConnection::cIsConnectionCmd(long theCmd)
- {
- return ((theCmd >= FIRST_CONN_CMD) && (theCmd <= LAST_CONN_CMD));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * cCheckToolName
- *
- * Checking existence of a tool by its name
- *
- * toolName: name of the tool (Pascal string)
- *
- * Return cmGenericError if the tool is not present
- *
- */
-
- OSErr CConnection::cCheckToolName(Str31 toolName)
- {
- return(CMGetProcID(toolName));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * cConnIdle
- *
- * Idle time for each connection object
- *
- *
- */
-
- /* Idle routine for each connection object */
-
- static void Conn_Idle(CConnection *theConn)
- {
- theConn->DoIdle();
- }
-
-
- void CConnection::cConnIdle(void)
- {
- if (cConnList != NULL) /* List exists ? */
- cConnList->DoForEach((EachFunc) Conn_Idle);
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * cInitManager
- *
- * Connection Manager Initialization
- *
- */
-
- void CConnection::cInitManager(void)
- {
- InitCM();
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * cGetCMVersion
- *
- * return the version of the Connection Manager
- *
- */
-
- short CConnection::cGetCMVersion(void)
- {
- return CMGetCMVersion();
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * IConnection
- *
- * Initialisation of the connection object
- *
- * aSupervisor: object supervisor in the command chain
- * toolName: name of the connection tool to be used ("" -> défault)
- * flags:(CM) how to use the connection tool
- * desiredSizes:(CM) desired sizes of sending and receiving buffers
- * refcon:(CM) available for the application
- * userData:(CM) available for the application
- *
- * Parameters followed by CM are exact required parameters for creating a
- * connection record.
- *
- */
-
- void CConnection::IConnection(CBureaucrat *aSupervisor,Str31 toolName,
- CMRecFlags flags,CMBufferSizes desiredSizes,
- long refCon, long userData)
- {
- ConnHandle theConn;
- OSErr theErr;
- Str31 tName;
- short toolProcID;
- Boolean savedAlloc;
-
- CBureaucrat::IBureaucrat(aSupervisor); /* Initialize superclass */
-
- if (toolName[0] == 0) { /* Default tool ? */
-
- theErr = CRMGetIndToolName(classCM,1,tName);
-
- if ((tName[0] == 0) || (theErr != cmNoErr)) /* Error checking */
- Failure(cmNoTools,SpecifyMsg(CONN_STR_RES_ID,NO_TOOL_STR_INDEX));
-
- toolProcID = CMGetProcID(tName); /* Default tool ID */
- }
- else {
- toolProcID = CMGetProcID(toolName); /* Specified tool ID */
- }
-
- if (toolProcID == cmGenericError) { /* No corresponding tool */
- Failure(cmNoTools,SpecifyMsg(CONN_STR_RES_ID,BAD_TOOL_STR_INDEX));
- }
-
- savedAlloc = SetAllocation(kAllocCanFail);
-
- theConn = CMNew(toolProcID,flags,desiredSizes,refCon,userData);
-
- SetAllocation(savedAlloc);
-
- FailNIL(theConn); /* Connection created ? */
-
- MoveHHi((Handle)theConn); /* Heap fragmentation… */
-
- itsConn = theConn;
-
- if (cConnList == NULL) { /* first connection object ? */
- cConnList = new(CCluster);
- cConnList->ICluster();
- }
-
- cConnList->Add(this); /* Connection addition */
-
- this->connOpen = FALSE;
-
- this->active = FALSE;
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * Dispose
- *
- * Dispose of a connection object
- *
- */
-
- void CConnection::Dispose(void)
- {
- ASSERT(cConnList != NULL);
-
- cConnList->Remove(this); /* Dispose of the Connection */
-
- if (cConnList->IsEmpty())
- ForgetObject(cConnList); /* Dispose of the cluster */
-
- CMDispose(itsConn); /* Dispose of the connection record */
- itsConn = NULL;
-
- inherited::Dispose(); /* Pass message to its superclass */
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * UpdateMenus
- *
- * Connection related menus updating
- *
- */
-
- void CConnection::UpdateMenus(void)
- {
-
- gBartender->EnableCmd(cmdConnChoose); /* Setup command */
-
- gBartender->EnableCmd(cmdConnReset); /* Connection reset */
-
- if (this->IsOpen()) { /* Connection open ? */
- gBartender->EnableCmd(cmdConnClose);
- gBartender->EnableCmd(cmdConnBreak);
- }
- else {
- gBartender->EnableCmd(cmdConnOpen);
- gBartender->EnableCmd(cmdConnListen);
- }
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * DoCommand
- *
- * Handle connection related commands
- *
- * theCommand: command to be executed
- *
- */
-
- void CConnection::DoCommand(long theCommand)
- {
- switch (theCommand) {
-
- case cmdConnChoose: /* Connection tool setup */
- this->ConnectionChoose();
- break;
-
- case cmdConnOpen: /* Connection opening */
- this->OpenConnection(FALSE,NULL,0L);
- break;
-
- case cmdConnListen: /* Connection listening */
- this->ListenConnection(FALSE,NULL,0L);
- break;
-
- case cmdConnClose: /* Connection waiting */
- this->CloseConnection(FALSE,NULL,0L,TRUE);
- break;
-
- case cmdConnReset: /* Connection reset */
- this->Reset();
- break;
-
- case cmdConnBreak: /* BREAK signal send */
- this->SendBreak();
- break;
-
- default: /* Unknown command */
- break;
- }
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * ConnectionChoose
- *
- * Connection tool setup
- *
- */
-
- void CConnection::ConnectionChoose(void)
- {
- short retCode;
- Point where;
- ConnHandle hConn;
-
- hConn = this->itsConn;
-
- SetPt(&where,H_CHOOSE_POS,V_CHOOSE_POS); /* Dialog position */
-
- retCode = CMChoose(&hConn,where,NULL);
-
- this->itsConn = hConn;
-
- switch (retCode) {
- case chooseCancel: /* Forget changes */
- break;
-
- case chooseOKMinor: /* Same tool, changed config */
- case chooseOKMajor: /* Changed tool */
-
- active = FALSE;
- Activate();
-
- itsSupervisor->Notify(NULL); /* Document updated */
-
- break;
-
- default: /* Unknown code (error) */
- SysBeep(3);
- gError->PostAlert(CONN_STR_RES_ID,CHOOSE_STR_INDEX);
- break;
- }
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * SetConfig
- *
- * Connection configuration change
- *
- * theConfig: new configuration (C string)
- *
- * Return: negative value: error (-1 -> unknown error)
- * positive value: stop index of the parser
- * cmNoErr if everything is OK
- *
- */
-
- short CConnection::SetConfig(char *theConfig)
- {
- short retCode;
-
- retCode = CMSetConfig(itsConn,theConfig);
-
- return retCode;
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * GetToolName
- *
- * Return the name of the current tool
- *
- * toolName: tool name (Pascal string)
- *
- */
-
- void CConnection::GetToolName(Str31 toolName)
- {
- SignedByte savedState;
-
- savedState = HGetState(itsConn);
- HLock(itsConn);
-
- CMGetToolName((*itsConn)->procID,toolName);
-
- HSetState(itsConn,savedState);
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * GetConfig
- *
- * Return a C string describing the current config of the connection
- *
- * Return a pointer on the string
- *
- */
-
- Ptr CConnection::GetConfig(void)
- {
- return(CMGetConfig(itsConn));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * getStatus
- *
- * Return the connection status
- *
- * sizes: Buffers sizes (sortie)
- * flags: Connection status (sortie)
- *
- * Return an error code
- *
- */
-
- OSErr CConnection::getStatus(CMBufferSizes *sizes,CMStatFlags *flags)
- {
- return(CMStatus(itsConn,*sizes,flags));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * OpenConnection
- *
- * Connection opening
- *
- * async: Opening mode (synchrone or asynchrone)
- * completor: asynchrone callback
- * timeOut: time period within which the opening must be completed
- *
- */
-
- void CConnection::OpenConnection(Boolean async,ProcPtr completor,long timeOut)
- {
- OSErr theErr;
-
- theErr = CMOpen(itsConn,async,completor,timeOut);
-
- if (theErr == cmNoErr) {
- this->connOpen = TRUE;
- BroadcastChange(connOpenInd,NULL);
- }
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * ListenConnection
- *
- * Connection listening
- *
- * async: Listening mode (synchrone or asynchrone)
- * completor: asynchrone callback
- * timeOut: time period within which the listening must be completed
- *
- */
-
- void CConnection::ListenConnection(Boolean async,ProcPtr completor,long timeOut)
- {
- OSErr theErr;
-
- theErr = CMListen(itsConn,async,completor,timeOut);
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * CloseConnection
- *
- * Connection closing
- *
- * async: Closing mode (synchrone or asynchrone)
- * completor: asynchrone callback
- * timeOut: time period within which the closing must be completed
- * now: immediately closing
- *
- */
-
- void CConnection::CloseConnection(Boolean async,ProcPtr completor,long timeOut,
- Boolean now)
- {
- OSErr theErr;
-
- theErr = CMClose(itsConn,async,completor,timeOut,now);
-
- if (theErr == cmNoErr) {
- this->connOpen = FALSE;
- BroadcastChange(connCloseInd,NULL);
- };
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * IsOpen
- *
- * Connection opening test
- *
- * Return TRUE if the connection is open
- *
- */
-
- Boolean CConnection::IsOpen(void)
- {
- CMBufferSizes sizes;
- CMStatFlags flags;
- OSErr theErr;
-
- theErr = this->getStatus(&sizes,&flags);
-
- if (theErr == cmNoErr)
- if (flags & cmStatusOpen) /* Connection open ? */
- return TRUE;
- else
- return FALSE;
- else
- return FALSE;
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * DataAvail
- *
- * Data available
- *
- * Return the number of available characters
- *
- */
-
- long CConnection::DataAvail(void)
- {
- CMBufferSizes sizes;
- CMStatFlags flags;
- OSErr theErr;
-
- theErr = this->getStatus(&sizes,&flags);
-
- if (theErr == cmNoErr)
- if (flags & cmStatusDataAvail) /* Data available ? */
- return sizes[cmDataIn]; /* Return receiving buffer size */
- else
- return 0;
- else
- return 0;
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * DataRead
- *
- * Reading of available data
- *
- * inBuffer: Receiving buffer
- * buffSize: Number of chars to read
- * async: Reading mode (asynchrone or synchrone)
- * completor: Reading callback
- * timeOut: time period within which the reading must be completed
- * flags: end-of-message indicator
- *
- * Return an error code
- *
- */
-
- OSErr CConnection::DataRead(Ptr inBuffer,long *buffSize,Boolean async,
- ProcPtr completor,long timeOut,CMFlags *flags)
- {
- return (CMRead(itsConn,inBuffer,buffSize,cmData,async,completor,timeOut,
- flags));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * DoIdle
- *
- * Idle time of the application
- *
- */
-
- void CConnection::DoIdle(void)
- {
- CMIdle(itsConn);
-
- if (!(this->IsOpen()) && this->connOpen) {
- this->connOpen = FALSE;
- BroadcastChange(connCloseInd,NULL);
- };
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * DataWrite
- *
- * Data writing
- *
- * inBuffer: Sending buffer
- * buffSize: Number of chars to send
- * async: Writing mode (synchrone or asychrone)
- * completor: Asynchrone writing callback
- * timeOut: time period within which the writing must be completed
- * flags: end-of-message indicator
- *
- * Return an error code
- *
- */
-
- OSErr CConnection::DataWrite(Ptr inBuffer,long *buffSize,Boolean async,
- ProcPtr completor,long timeOut,CMFlags flags)
- {
- return (CMWrite(itsConn,inBuffer,buffSize,cmData,async,completor,timeOut,
- flags));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * Activate
- *
- * Connection activation
- *
- */
-
- void CConnection::Activate(void)
- {
- if (!active) {
- CMActivate(itsConn,TRUE);
- active = TRUE;
- }
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * Deactivate
- *
- * Connection desactivation
- *
- */
-
- void CConnection::Deactivate(void)
- {
- if (active) {
- CMActivate(itsConn,FALSE);
- active = FALSE;
- }
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * Reset
- *
- * Connection reset
- *
- */
-
- void CConnection::Reset(void)
- {
- short response;
-
- PositionDialog('ALRT', RESET_ALRT_ID);
-
- InitCursor();
-
- response = Alert(RESET_ALRT_ID, NULL);
-
- if (response == answerNO)
- CMReset(itsConn);
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * SendBreak
- *
- * BREAK signal sending
- *
- */
-
- void CConnection::SendBreak(void)
- {
- CMBreak(itsConn,BREAK_DELAY,FALSE,NULL);
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * GetEnvirons
- *
- * Return the connection environs
- *
- * theEnvirons: Pointer on the environs record
- *
- * Return an error code
- *
- */
-
- OSErr CConnection::GetEnvirons(ConnEnvironRecPtr theEnvirons)
- {
- return(CMGetConnEnvirons(itsConn,theEnvirons));
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-